//
//  NXFlowLayout.h
//  项目A --半糖
//
//  Created by romana on 16/6/3.
//  Copyright © 2016年 romana. All rights reserved.
//

#import <UIKit/UIKit.h>

@class NXFlowLayout;

@protocol NXFlowLayoutDelegate <NSObject>

-(CGFloat)NXFlowLayout:(NXFlowLayout *)flowLayout heightForItemAtIndexPath:(NSIndexPath *)indexPath width:(CGFloat)width;

@end

@interface NXFlowLayout : UICollectionViewLayout

{
    
    CGFloat page;
    int pageNum;
    int columnNum;
    int rowNum;
}


@property(nonatomic,assign)NSInteger colum;//多少列
@property(nonatomic,assign)NSInteger row;//多少行

@property(nonatomic,assign)UIEdgeInsets edgeInsets;//距离屏幕四周的边界距离

@property(nonatomic,assign)NSInteger columSpace;//列间距
@property(nonatomic,assign)NSInteger rowSpace;//行间距

@property(nonatomic,assign)id<NXFlowLayoutDelegate>ytDelegate;

@property(nonatomic,assign)NSInteger totalPage;
@property(nonatomic,assign)NSInteger itemCounts;//item的个数
@property(nonatomic,assign)NSInteger currentPage;



@end
